package com.xiaocg.factory;

import java.text.DateFormat;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.Iterator;
import java.util.List;

public class CoffeeTest {
    public static void main(String[] args) {
        /*CoffeeStore store = new CoffeeStore();
        store.orderCoffee("latte");*/

        Coffee latte = ConfigFileFactory.createCoffee("latte");
        System.out.println(latte.getName());

        List<String> list = new ArrayList<>();
        list.add("1");
        list.add("2");
        list.add("3");

        Iterator<String> iterator = list.iterator();
        while (iterator.hasNext()){
            String next = iterator.next();
            System.out.println(next);
        }

        DateFormat instance = DateFormat.getInstance();
        Calendar instance1 = Calendar.getInstance();
    }
}
